package cn.gene.timeyan.ums.webapi.ums.controller;


import cn.gene.timeyan.common.restful.JsonResult;
import cn.gene.timeyan.pojo.coo.dto.CooperationDTO;
import cn.gene.timeyan.pojo.ums.dto.ReportDTO;
import cn.gene.timeyan.ums.service.IReportService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 对违规用户的举报 前端控制器
 * </p>
 *
 * @author LWG
 * @since 2022-08-07
 */
@Slf4j
@RestController
@RequestMapping("/report")
@Api(tags="举报模块")
public class ReportController {

    /**
     * cyn
     */
    @Autowired(required = false)
    private IReportService service;

    @ApiOperation("举报功能")
    @PostMapping("/addReportUsers")
    public JsonResult<Void> addNew(@Validated ReportDTO reportDTO){
        log.info("dto====:{}",reportDTO);
       service.addReportUsers(reportDTO);
        return JsonResult.ok();
    }
}

